package sg.nus.iss.vmcs.guilisteners;

import java.awt.event.ActionListener;
import java.awt.event.ActionEvent;
import sg.nus.iss.vmcs.controllers.MaintenanceController;

/**
 * Action Listener for the Total Cash Button on the Maintenance Panel 
 * @author Pang Pingli
 */
public class TotalCashButtonListener implements ActionListener {
	
	/** Maintennce Controller */
	private MaintenanceController mctrl;

	/**
	 * Creates an instance of the Total Cash Button Listener
	 * @param mc Reference to MaintenanceController
	 */
	public TotalCashButtonListener(MaintenanceController mc) {
		mctrl = mc;
	}
	
	/**
	 * Implementation of actionPerformed
	 */
	public void actionPerformed(ActionEvent e) {
    	mctrl.getTotalCash();
	}
}